public class ForDemo1 {
    public static void main(String[] args) {
        //for循环初始化语句；循环条件；迭代语句
        //for循环快捷键fori
        //最常用
        System. out. println("----3次 Hello world----");
        for ( int i = 0; i < 3; i++) {
            //i = 0,i = 1,i = 2
            System. out. println(" Hello world");
        }
        System. out. println("----4次 Hello MySQL----");
        for ( int i = 1; i < 5; i++) {
            //i = 1,i = 2,i =3,i = 4
            System. out. println(" Hello MySQL");
        }
        System. out. println("----5次 Hello Spring----");
        for ( int i = 1; i <= 5; i++) {
            //i = 1,i = 2,i = 3,i = 4,i = 5
            System. out. println(" Hello Spring");
        }
        System. out. println("----3次 Hello Redis----");
        for ( int i = 1; i <= 5; i += 2) {
            //i = 1,i = 3,i = 5
            System. out. println(" Hello Redis");
        }
    }
}
